package com.yonyou.pmclouds.repeatwork.service.rmiitf;

import com.yonyou.pmclouds.basecom.entity.PageObject;
import com.yonyou.pmclouds.basecom.exception.BusinessException;
import com.yonyou.pmclouds.billview.entity.BillViewQueryVO;
import com.yonyou.pmclouds.repeatwork.entity.RepeatWorkVO;

import java.util.Map;

public interface IRepeatWorkQuery {
    /**
     * 根据复工单主键查询复工单
     * @param pkRepeatwork
     * @return
     * @throws BusinessException
     */
    RepeatWorkVO queryOneByPk(String pkRepeatwork) throws BusinessException;

    /**
     * 根据项目主键查询复工单
     * @param pkProject
     * @return
     * @throws BusinessException
     */
    RepeatWorkVO queryByProject(String pkProject) throws BusinessException;

    /**
     * 通过报告ID查询停工报告
     * @param reportId
     * @return
     * @throws BusinessException
     */
    RepeatWorkVO getReport(String reportId) throws BusinessException;
    /**
     * 根据条件查询停工条件
     */
    PageObject<Object> queryByCondition(String[] pkProject,
                                        String[] creators,
                                        String startDate,
                                        String endDate,
                                        int[] billStatus,
                                        int start,
                                        int size) throws BusinessException;

    /**
     * 根据主键查询出实体
     * @param ids
     * @return
     * @throws BusinessException
     */
    Map<String,RepeatWorkVO> queryByIDs(String[] ids) throws BusinessException;

    /**
     * 根据参数查询实体
     * @param billViewQueryVO
     * @return
     * @throws BusinessException
     */
    PageObject<Object>  queryByCondition(BillViewQueryVO billViewQueryVO) throws BusinessException;

    /**
     * 根据单据状态查询指定项目的复工单。
     * @param pkProject
     * @param status
     * @return
     * @throws BusinessException
     */
    RepeatWorkVO[] queryByStatus(String pkProject,int[] status) throws BusinessException;
}
